package com.gxa.service.impl;

import com.gxa.dao.VisitorMapper;
import com.gxa.pojo.Visitor;
import com.gxa.service.VisitorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @description: TODO
* @author JZ
* @date 2022/9/2 15:42
* @version 1.0
*/
@Service("visitorService")
public class VisitorServiceImpl implements VisitorService {

    @Autowired
    VisitorMapper mapper;

    @Override
    public boolean insertVisitor(Visitor visitor) {
        return mapper.insertVisitor(visitor)>0;
    }

    @Override
    public boolean deleteVisitor(int id) {
        return mapper.deleteVisitor(id)>0;
    }

    @Override
    public List<Visitor> selectVisitor(Visitor visitor) {
        return mapper.selectVisitor(visitor);
    }

    @Override
    public boolean updateVisitor(Visitor visitor) {
        return mapper.updateVisitor(visitor)>0;
    }
}
